﻿<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="sysfunc" uri="/systemFunctions" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<link href="/res/css/style.css" rel="stylesheet" type="text/css" />
<script language="JavaScript" src="/res/js/jquery.js"></script>

<script type="text/javascript">
$(function(){	
	//导航切换
	$(".menuson li").click(function(){
		$(".menuson li.active").removeClass("active")
		$(this).addClass("active");
	});
	
	$('.title').click(function(){
		if($('.title').length==1){
			$(this).next('ul').slideDown();
			return;
		}
		var $ul = $(this).next('ul');
		$('dd').find('ul').slideUp();
		if($ul.is(':visible')){
			$(this).next('ul').slideUp();
		}else{
			$(this).next('ul').slideDown();
		}
	});
	$('dd').find('ul').show();
})	
</script>


</head>

<body style="background:#f0f9fd;">
	<div class="lefttop"><span>
		<c:forEach items="${module_list}" var="md1">
			<c:if test="${md1.level==1 && md1.id==param.pid}">
				</span>${md1.name}
		    </c:if>
	    </c:forEach>	
	</div>
    
    <dl class="leftmenu">    
        <c:set var="m2Status" value="0" />
        <c:set var="m3Status" value="0" />
	    <c:forEach items="${module_list}" var="md">
	    <c:if test="${md.level==2 && md.parentId==param.pid && sysfunc:checkUserModule(md.id)}">
	        <c:set var="m2Status" value="${m2Status+1}" />
		    <dd>
			    <div class="title">
			    	<span><img src="/res/images/leftico01.png" /></span>${md.name}
			    </div>
		    	<ul class="menuson">
				    <c:forEach items="${module_list}" var="mditem">
			    	<c:if test="${mditem.level==3 && mditem.parentId==md.id}"> 
			    	   <c:if test="${sysfunc:checkUserModule(mditem.id)}">
			    	    <c:set var="m3Status" value="${m3Status+1}" />   
			    	 	<li ${m3Status==1?"class='active'":""}><cite></cite><a href="${mditem.url}" target="rightFrame">${mditem.name}</a><i></i>
			    	 	    <c:if test="${m3Status==1}">
			    	 	       <script>$(function(){
			    	 	    	   var fra = window.parent.$.find("#rightFrame");
			    	 	    	   fra[0].contentWindow.location.href="${mditem.url}";
			    	 	       });</script> 
			    	 	    </c:if>
			    	 	</li>
			    	   </c:if> 	
				    </c:if>
				    </c:forEach> 
		        </ul>    
		    </dd>
	    </c:if>
	    </c:forEach>
    </dl>
    
</body>
</html>
